import { BrowserModule } from "@angular/platform-browser";
import { BrowserAnimationsModule } from "@angular/platform-browser/animations";
import { NgModule } from "@angular/core";
import { FormsModule } from "@angular/forms";
import { ReactiveFormsModule } from "@angular/forms";
import { HttpModule } from "@angular/http";
import { NgZorroAntdModule } from "ng-zorro-antd";
import { NZ_MESSAGE_CONFIG } from "ng-zorro-antd";
import { NZ_NOTIFICATION_CONFIG } from "ng-zorro-antd";
import { AppComponent } from "./app.component";
import { AppRoutingModule } from "./app.routing.module";
import { HttpClientModule } from "@angular/common/http";
import { HttpClient } from "@angular/common/http";
import {
  CommonModule,
  LocationStrategy,
  HashLocationStrategy
} from "@angular/common";
import { FileUploadModule } from "ng2-file-upload";

// 页面
import { Login } from "./pages/login/login";
import { Home } from "./pages/home/home";
import { UserPage } from "./pages/user/user/user";
import { UserAddPage } from "./pages/user/user/user-add/user-add";
import { UserModifyPage } from "./pages/user/user/user-modify/user-modify";
import { RolePage } from "./pages/user/role/role";
import { FunctionPage } from "./pages/user/function/function";
import { FunctionAddPage } from "./pages/user/function/function-add/function-add";
import { FunctionModifyPage } from "./pages/user/function/function-modify/function-modify";
import { PartyPage } from "./pages/user/party/party";
import { RoleAddPage } from "./pages/user/role/role-add/role-add";
import { RoleModifyPage } from "./pages/user/role/role-modify/role-modify";
import { PartyAddPage } from "./pages/user/party/party-add/party-add";
import { PartyModifyPage } from "./pages/user/party/party-modify/party-modify";
import { ElevatorInfoPage } from "./pages/elevator/elevator-info/elevator-info";
import { ElevatotAddPage } from "./pages/elevator/elevator-info/elevator-add/elevator-add";
import { ElevatotModifyPage } from "./pages/elevator/elevator-info/elevator-modify/elevator-modify";
import { ElevatotBatchModifyPage} from "./pages/elevator/elevator-info/elevator-batch-modify/elevator-batch-modify";
import { ElevatotMaintenancePage } from "./pages/elevator/elevator-info/elevator-maintenance/elevator-maintenance";
import { MaintenanceListPage } from "./pages/elevator/maintenance-list/maintenance-list";
import { DebrisPage } from "./pages/elevator/elevator-kinds/debris/debris"; //杂物电梯列表
import { DebrisHalfMonPage } from "./pages/elevator/elevator-kinds/debris/half-mon/debris-half-mon"; //杂物电梯半月保
import { DebrisHalfYearPage } from "./pages/elevator/elevator-kinds/debris/half-year/debris-half-year"; //杂物电梯半年保
import { DebrisQuarterPage } from "./pages/elevator/elevator-kinds/debris/quarter/debris-quarter"; //杂物电梯季度保
import { DebrisYear } from "./pages/elevator/elevator-kinds/debris/year/debris-year"; //杂物电梯年保
import { EscalatorPage } from "./pages/elevator/elevator-kinds/escalator/escalator"; //自动扶梯与人行道列表
import { EscalatorHalfMonPage } from "./pages/elevator/elevator-kinds/escalator/half-mon/escalator-half-mon"; //自动扶梯与人行道半月保
import { EscalatorHalfYearPage } from "./pages/elevator/elevator-kinds/escalator/half-year/escalator-half-year"; //自动扶梯与人行道半年保
import { EscalatorQuarterPage } from "./pages/elevator/elevator-kinds/escalator/quarter/escalator-quarter"; //自动扶梯与人行道季度保
import { EscalatorYearPage } from "./pages/elevator/elevator-kinds/escalator/year/escalator-year"; //自动扶梯与人行道年保
import { HydpressPage } from "./pages/elevator/elevator-kinds/hydpress/hydpress"; //液压电梯列表
import { HydpressHalfMonPage } from "./pages/elevator/elevator-kinds/hydpress/half-mon/hydpress-half-mon"; //液压电梯半月保
import { HydpressHalfYearPage } from "./pages/elevator/elevator-kinds/hydpress/half-year/hydpress-half-year"; //液压电梯半年保
import { HydpressQuarterPage } from "./pages/elevator/elevator-kinds/hydpress/quarter/hydpress-quarter"; //液压电梯季度保
import { HydpressYearPage } from "./pages/elevator/elevator-kinds/hydpress/year/hydpress-year"; //液压电梯年保
import { TractionPage } from "./pages/elevator/elevator-kinds/traction/traction"; //曳引电梯列表
import { TractionHalfMonPage } from "./pages/elevator/elevator-kinds/traction/half-mon/traction-half-mon"; //曳引电梯半月保
import { TractionHalfYearPage } from "./pages/elevator/elevator-kinds/traction/half-year/traction-half-year"; //曳引电梯半年保
import { TractionQuarterPage } from "./pages/elevator/elevator-kinds/traction/quarter/traction-quarter"; //曳引电梯季度保
import { TractionYearPage } from "./pages/elevator/elevator-kinds/traction/year/traction-year"; //曳引电梯年保
import { MaintenancePlan } from "./pages/maintenancePlan/maintenancePlan"; //维保计划
import { MaintenancePlanAdd } from "./pages/maintenancePlan/add/maintenance-plan.add"; //维保计划

import { OnelevatorInfoPage } from "./pages/elevator/onelevator/onelevator-info"; //一梯一档主页面
import { MaintenancePage } from "./pages/elevator/maintenance-record/maintenance-record"; //电梯维修记录页
import { MaintenanceDetailPage } from "./pages/elevator/maintenance-record/maintenance-detail/maintenance-detail"; //电梯维修记录详情页
import { InspectionPage } from "./pages/elevator/inspection-record/inspection-record"; //elevatorLedger查询（物业）主页面
import { InspectionDetailPage } from "./pages/elevator/inspection-record/inspection-detail/inspection-detail"; //巡检记录查询（物业）详情页
import { InformationPage } from "./pages/user/information/information"; //资讯管理页面
import { InformationAddPage } from "./pages/user/information/information-add/information-add";
import { InformationModifyPage } from "./pages/user/information/information-modify/information-modify";
import { InformationDetailPage } from "./pages/user/information/information-detail/information-detail";
import { ElevatorAppraisalPage } from "./pages/elevator/elevator-appraisal/elevator-appraisal"; // 电梯评价表
import { RescueDrillPage } from "./pages/elevator/rescueDrill/rescueDrill";
import { MainPage } from "./pages/home/main/main";
import { NoticePage } from "./pages/notice/notice/notice";
import { NoticeAddPage } from "./pages/notice/notice/notice-add/notice-add";
import { NoticeModifyPage } from "./pages/notice/notice/notice-modify/notice-modify";
import { UsedPartyDetailPage } from "./pages/notice/used-party-detail/used-party-detail";
import { MaintenancePartyDetailPage } from "./pages/notice/maintenance-party-detail/maintenance-party-detail";
import { DetailsPage } from "./pages/notice/details/details";
import { ComplaintHis } from "./pages/complaintHis/complaintHis";
import { RoleTypePage } from "./pages/user/roleType/role-type";
import { RoleTypeAddPage } from "./pages/user/roleType/add/role-type.add";
import { RoleTypeUpdatePage } from "./pages/user/roleType/update/role-type.update";
import { ContractPage } from "./pages/contract/contract"; //合同管理
import { ContractAddPage } from "./pages/contract/contract-add/contract-add"; //合同管理--添加
import { ContractModifyPage } from "./pages/contract/contract-modify/contract-modify"; //合同管理--修改
import { Advertisement } from "./pages/Advertisement/advertisement"; //轮播广告
import { AdvertisementAdd } from "./pages/Advertisement/add/advertisement.add";
import { AdvModifyPage} from "./pages/Advertisement/adv-modify/adv-modify";

//管道
import { PartyTypePipe } from "./service/pipes/partyTypePip";
import { LittlePipe } from "./service/pipes/littlePipe";
import { TimePipe } from "./service/pipes/timePipe";
import { DateFormat } from "./service/pipes/dateFormat";
import { ConstantTransferPipe } from "./service/pipes/constantTransferPipe";

// 服务
import { HttpServcie } from "./service/http.service";
import { CommFuntion } from "./service/commFunction";
import { PermissionService } from "./service/permission.service";
import { GlobalVars } from "./service/globalVars";

//组件
import { EnlargePic } from "./components/enlarge-pic";
import { CKEditorModule } from "ngx-ckeditor";
import { ElevatorRescuePage } from "./pages/elevator/elevator-rescue/elevator-rescue.component";
import { RescueDetailComponent } from "./pages/elevator/elevator-rescue/rescue-detail/rescue-detail.component";
import { PermissionDirctive } from "./components/permissionDirective/permission.directive";

import { NgxEchartsModule } from "ngx-echarts";
import { SuperviserParty } from "./pages/home/superviser-party/superviser-party";
import { SuperviserSafe } from "./pages/home/superviser-safe/superviser-safe";
import { SuperviserLiability } from "./pages/home/superviser-liability/superviser-liability";
import { SuperviserEle } from "./pages/home/superviser-ele/superviser-ele";
import { SuperviserCheck } from "./pages/home/superviser-check/superviser-check";

//注册
import { RegisterComponent } from "./pages/register/register.component";
import { Checklist } from "./pages/register-check/register-check-list/register-check-list";
import { Checkdetail } from "./pages/register-check/register-check-detail/register-check-detail";
import { RegisterApproveComponent } from "./pages/register-check/register-approve/register-approve.component";
import { ElevatorUnitFileComponent } from "./pages/elevator/elevator-info/elevator-unit-file/elevator-unit-file.component";
import { userAgreementComponent } from "./pages/register/user-agreement/user-agreement";

//监管
import { SafeControlRecord } from "./pages/safe-control-record/safeControlRecord";
import { SafeControlRecordDetail } from "./pages/safe-control-record/detail/safeControlRecordDetail";

// 电梯安全状态
import { ElevatorSecureState } from "./pages/elevator/elevator-secure-state/elevator-secure-state";
import { AnnualSummary } from "./pages/elevator/elevator-secure-state/annual-summary/annual-summary";
import { BasicInformation } from "./pages/elevator/elevator-secure-state/basic-information/basic-information";
import { CurrentTimeState } from "./pages/elevator/elevator-secure-state/current-time-state/current-time-state";
import { DutyRankingList } from "./pages/elevator/elevator-secure-state/duty-ranking-list/duty-ranking-list";
// 电梯安全管理制度
import { ElevatorSafeManagementComponent } from "./pages/elevator/elevator-safe-management/elevator-safe-management";
import { InspectionFtDetailPage } from "./pages/elevator/inspection-record/inspection-ftdetail/inspection-ftdetail";
import { SelfCheckPage } from "./pages/elevator/elevator-self-check/self-check.component";
import { SelfCheckDetailComponent } from "./pages/elevator/elevator-self-check/self-check-detail/self-check-detail.component";
import { BaiduMapModule } from "angular2-baidu-map";
import { MapDemo } from "./pages/home/map-demo/map-demo";
import { PlanDict } from "./pages/supervision/plan/plan-dict/plan-dict";
import { PlanDictAddPage } from "./pages/supervision/plan/plan-dict/add/plan-dict-add";
import { PlanDictModPage } from "./pages/supervision/plan/plan-dict/update/plan-dict-mod";
import { PlanDetail } from "./pages/supervision/plan/plan-detail/plan-detail";
import { PlanDetailModPage } from "./pages/supervision/plan/plan-detail/mod/plan-detail-mod";
import { PlanDetailPublishPage } from "./pages/supervision/plan/plan-detail/publish/plan-detail-publish";
import { CheckItemPage } from "./pages/supervision/plan/check-item/check-item";
import { SafeControlRecordNew } from "./pages/supervision/safe-control-record/safeControlRecordNew";
import { PublicRandom } from "./pages/supervision/public-random/public-random";
import { PublicRandomAddPage } from "./pages/supervision/public-random/add/public-random-add";
import { PublicRandomModPage } from "./pages/supervision/public-random/update/public-random-mod";
import { PublicRandomSelectPage } from "./pages/supervision/public-random/public-random-select/public-random-select";
import { SelfCountPage } from "./pages/home/self-count/self-count";

// 用户转移
import { Transferlist } from "./pages/transfer-check/transfer-check-list/transfer-check-list";
import { Transferdetail } from "./pages/transfer-check/transfer-check-detail/transfer-check-detail";
import { TransferApproveComponent } from "./pages/transfer-check/transfer-approve/transfer-approve.component";
import { BlankPage } from "./pages/blank-page/blank-page";
import { DynamicForm } from "./pages/DynamicForm/dynamic-form";
import { DynamicAdd } from "./pages/DynamicForm/dynamic-add/dynamic-add";
import { DynamicModify } from "./pages/DynamicForm/dynamic-modify/dynamic-modify";
import { ReportSql} from "./pages/DynamicForm/report-sql/report-sql";
import { SpotCheck} from "./pages/maintenancePlan/spot-check/spot-check";
import { SpotCheckAdd} from "./pages/maintenancePlan/spot-check-add/spot-check-add";
import { SpotCheckItem} from "./pages/maintenancePlan/spot-check-item/spot-check-item";
import { SpotObjectDetail} from "./pages/maintenancePlan/spot-object-detail/spot-object-detail";
import { SpotObjectAdd} from "./pages/maintenancePlan/spot-object-add/spot-object-add";
import {SpotObjectModify} from "./pages/maintenancePlan/spot-object-detail/spot-object-modify/spot-object-modify";

import { TrainingPlan } from "./pages/training/trainingPlan";
import { TrainingPlanAdd } from "./pages/training/trainingPlan-add/trainingPlan-add";
import { TrainingPlanUpdate } from "./pages/training/trainPlan-update/trainingPlan-update";
import { TrainingPlanDetail } from "./pages/training/trainingPlan-detail/trainingPlan-detail";
import {TrainingPlanResult} from "./pages/training/trainingPlan-result/trainingPlan-result";
import {TrainingPlanDetailUpdate} from "./pages/training/trainingPlan-detail/trainingPlan-detail-update/trainingPlan-detail-update";
import {SpotObjectCensus} from "./pages/maintenancePlan/spot-check-census/spot-object-census";
import {SystemInterface} from "./pages/DynamicForm/system-interface/system-interface";
import {SpotObjectDetailsInterface} from "./pages/maintenancePlan/spot-check-census/spot-object-detailsInterface/spot-object-detailsInterface";
import {PointDefend} from "./pages/point/point-defend";
import {PointDefendAdd} from "./pages/point/point-defend-add/point-defend-add";
import {PointFlow} from "./pages/point/point-flow/point-flow";
import {PointFlowAdd} from "./pages/point/point-flow-add/point-flow-add";
import {DemandMaintenancePage} from "./pages/demand-maintenance/apply/demandMaintenance";
import {DemandMaintenanceAdd} from "./pages/demand-maintenance/apply/add/demandMaintenance-add";
import {DemandMaintenanceUpdate} from "./pages/demand-maintenance/apply/update/demandMaintenance-update";
import {DemandMaintenanceApproval} from "./pages/demand-maintenance/approval/demandMaintenance-approval";
import {DemandMaintenanceElevator} from "./pages/demand-maintenance/apply/elevator/demandMaintenance-elevator";
import {WorkOrder} from "./pages/elevator/elevator-rescue/work-order/work-order";
import {InformationAgent} from "./pages/home/information/information-agent";
import {DetectionRecord} from "./pages/detection/detection-record/detection-record";
import {PaperlessMaintApply} from "./pages/paperless-maintenance/apply/paperlessmaint-apply";
import {PaperlessMaintAdd} from "./pages/paperless-maintenance/apply/add/paperlessMaint-add";
import {PaperlessMaintApproval} from "./pages/paperless-maintenance/approval/paperlessMaint-approval";
import {PaperlessMaintElevator} from "./pages/paperless-maintenance/apply/elevator/paperlessMaint-elevator";
import {PaperlessMaintUpdate} from "./pages/paperless-maintenance/apply/update/paperlessMaint-update";
import {ContractProjectPage} from "./pages/contract/contract-project/contract-project";
import {ContractProjectAddPage} from "./pages/contract/contract-project/contract-project-add/contract-project-add";
import {ContractProjectElevator} from "./pages/contract/contract-project/contract-project-elevator/contract-project-elevator";
import {ContractProjectUpdatePage} from "./pages/contract/contract-project/contract-project-update/contract-project-update";
import {NooWnerInfoPage} from "./pages/elevator/elevator-noowner/elevator-noowner";
import {ElevatotNoownerModifyPage} from "./pages/elevator/elevator-noowner/elevator-noowner-modify/elevator-noowner-modify";
import {UnconfirmedMaintenance} from "./pages/elevator/unconfirmed-maintenance/unconfirmed-maintenance";
import {NeedconfirmMaintenance} from "./pages/elevator/unconfirmed-maintenance/needconfirm-maintenance/needconfirm-maintenance";

@NgModule({
  declarations: [
    MapDemo,
    AppComponent,
    Login,
    Home,
    UserPage,
    RolePage,
    FunctionPage,
    FunctionAddPage,
    FunctionModifyPage,
    PartyPage,
    RoleAddPage,
    RoleModifyPage,
    PartyAddPage,
    PartyModifyPage,
    PartyTypePipe,
    UserAddPage,
    UserModifyPage,
    EnlargePic,
    ElevatorInfoPage,
    ElevatotAddPage,
    SuperviserLiability,
    SuperviserParty,
    ElevatotModifyPage,
    ElevatotBatchModifyPage,
    SuperviserSafe,
    SuperviserEle,
    SuperviserCheck,
    ElevatotMaintenancePage,
    DebrisPage,
    MaintenanceListPage,
    DebrisHalfMonPage,
    DebrisHalfYearPage,
    DebrisQuarterPage,
    DebrisYear,
    EscalatorPage,
    EscalatorHalfMonPage,
    EscalatorHalfYearPage,
    EscalatorQuarterPage,
    EscalatorYearPage,
    HydpressPage,
    HydpressHalfMonPage,
    HydpressHalfYearPage,
    HydpressQuarterPage,
    HydpressYearPage,
    TractionPage,
    TractionHalfMonPage,
    TractionHalfYearPage,
    TractionQuarterPage,
    TractionYearPage,
    OnelevatorInfoPage,
    MaintenancePage,
    MaintenanceDetailPage,
    InspectionPage,
    InspectionDetailPage,
    RescueDrillPage,
    InformationPage,
    InformationAddPage,
    InformationModifyPage,
    InformationDetailPage,
    ElevatorAppraisalPage,
    NoticePage,
    NoticeAddPage,
    NoticeModifyPage,
    UsedPartyDetailPage,
    MaintenancePartyDetailPage,
    DetailsPage,
    LittlePipe,
    TimePipe,
    DateFormat,
    ConstantTransferPipe,
    ElevatorRescuePage,
    RescueDetailComponent,
    ComplaintHis,
    MainPage,
    PermissionDirctive,
    RoleTypePage,
    RoleTypeAddPage,
    RoleTypeUpdatePage,
    RegisterComponent,
    Checklist,
    Checkdetail,
    RegisterApproveComponent,
    ContractPage,
    ElevatorUnitFileComponent,
    ContractAddPage,
    ContractModifyPage,
    ContractProjectPage,
    ContractProjectAddPage,
    ContractProjectElevator,
    ContractProjectUpdatePage,
    Advertisement,
    AdvertisementAdd,
    userAgreementComponent,
    SafeControlRecord,
    SafeControlRecordDetail,
    ElevatorSecureState,
    AnnualSummary,
    BasicInformation,
    CurrentTimeState,
    DutyRankingList,
    ElevatorSafeManagementComponent,
    MaintenancePlan,
    MaintenancePlanAdd,
    InspectionFtDetailPage,
    SelfCheckPage,
    SelfCheckDetailComponent,
    PlanDict,
    PlanDictAddPage,
    PlanDictModPage,
    PlanDetail,
    PlanDetailModPage,
    PlanDetailPublishPage,
    CheckItemPage,
    SafeControlRecordNew,
    PublicRandom,
    PublicRandomAddPage,
    PublicRandomModPage,
    PublicRandomSelectPage,
    SelfCountPage,
    Transferlist,
    Transferdetail,
    TransferApproveComponent,
    BlankPage,
    AdvModifyPage,
    DynamicForm,
    DynamicAdd,
    DynamicModify,
    ReportSql,
    SpotCheck,
    SpotCheckAdd,
    SpotCheckItem,
    SpotObjectAdd,
    SpotObjectModify,
    SpotObjectDetail,
    ReportSql,
    TrainingPlan,
    TrainingPlanAdd,
    TrainingPlanUpdate,
    TrainingPlanDetail,
    TrainingPlanResult,
    TrainingPlanDetailUpdate,
    SpotObjectCensus,
    SystemInterface,
    SpotObjectDetailsInterface,
    PointDefend,
    PointDefendAdd,
    PointFlow,
    PointFlowAdd,
    DemandMaintenancePage,
    DemandMaintenanceAdd,
    DemandMaintenanceUpdate,
    DemandMaintenanceElevator,
    DemandMaintenanceApproval,
    PaperlessMaintApply,
    PaperlessMaintApproval,
    PaperlessMaintAdd,
    PaperlessMaintUpdate,
    PaperlessMaintElevator,
    WorkOrder,
    InformationAgent,
    DetectionRecord,
    NooWnerInfoPage,
    ElevatotNoownerModifyPage,
    UnconfirmedMaintenance,
    NeedconfirmMaintenance,
  ],
  imports: [

    BaiduMapModule.forRoot({ ak: "nb7uvaDhNTS30ujqQZcLT2PybRSB1QYE" }),
    BrowserModule,
    FormsModule,
    HttpModule,
    BrowserAnimationsModule,
    AppRoutingModule,
    ReactiveFormsModule,
    HttpClientModule,
    CommonModule,
    FileUploadModule,
    CKEditorModule,
    NgxEchartsModule,
    NgZorroAntdModule.forRoot()
  ],
  providers: [
    HttpClient,
    HttpServcie,
    PermissionService,
    GlobalVars,
    CommFuntion,
    //加入 hash模式 /#/ 解决刷新页面 nginx404问题
    { provide: LocationStrategy, useClass: HashLocationStrategy },
    {
      provide: NZ_MESSAGE_CONFIG,
      useValue: { nzDuration: 3000 }
    },
    {
      provide: NZ_NOTIFICATION_CONFIG,
      useValue: { nzDuration: 3000 }
    }
  ],
  bootstrap: [AppComponent]
})
export class AppModule { }
